import { OrderCouponInfo, OrderCouponParam } from '@/types/orderCoupon'
import fetch, { BaseResponse, BaseSimpleResponse, loginUrl, RequestContentType } from './index'
/**
 *订单优惠券列表
 * @param param  类型OrderCouponParam位置@/types/orderCoupon
 * @returns 订单优惠券列表
 */
export async function ordercouponlist(
  param: OrderCouponParam,
): Promise<BaseResponse<OrderCouponInfo>> {
  const { data } = await fetch.post<BaseResponse<OrderCouponInfo>>(
    '/api/cardcoupon/touch/usercoupon/ordercouponlist',
    {
      ...param,
    },
    { contentType: RequestContentType.FORM_URLENCODED },
  )
  return data
}
